package com.zhbit.service;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.transaction.annotation.Transactional;

import com.zhbit.dao.StudentScoreDao;
import com.zhbit.dao.StudentScoreDaoImpl;
import com.zhbit.domain.StudentScore;
@Transactional
public class StudentScoreServiceImpl implements StudentScoreService {
	@Resource
	StudentScoreDao stuscoreDao;
	
	@Override
	public boolean add(int id, String username, String subject, float score) {
		//stuscoredao = new StudentScoreDaoImpl();
		
		return stuscoreDao.add(id, username, subject, score);
	}

	@Override
	public List findByPage(int pageNo) {
		//stuscoredao = new StudentScoreDaoImpl();
		return stuscoreDao.findByPage(pageNo);
	}

	public boolean update(StudentScore stuscore) {
		//stuscoredao = new StudentScoreDaoImpl();
		return stuscoreDao.update(stuscore);
	}

	@Override
	public boolean delstu(StudentScore stuscore) {
		//stuscoredao = new StudentScoreDaoImpl();
		return stuscoreDao.delstu(stuscore);
	}

}
